package lq.cloud.studyserversystem;

import lq.common.annotation.EnableStudyAuthExceptionHandler;
import lq.common.annotation.EnableStudyServerProtect;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.security.config.annotation.method.configuration.EnableGlobalMethodSecurity;
import org.springframework.transaction.annotation.EnableTransactionManagement;

@EnableDiscoveryClient  // 开启服务注册与发现
@EnableGlobalMethodSecurity(prePostEnabled = true) //开启Spring Cloud Security权限注解(因为在StudyServerSystemResourceServerConfigure配置类中进行了访问配置)
@SpringBootApplication
@EnableStudyAuthExceptionHandler
@EnableStudyServerProtect
//@StudyCloudApplication
// 开启注解,方便使用@Transactional注解
@EnableTransactionManagement
@MapperScan("lq.cloud.studyserversystem.mapper")
public class StudyServerSystemApplication {

    public static void main(String[] args) {
        SpringApplication.run(StudyServerSystemApplication.class, args);
    }

}
